.class public Lcom/hierynomus/spnego/b;
.super Lcom/hierynomus/spnego/d;
.source "NegTokenTarg.java"


# instance fields
.field private c:Ljava/math/BigInteger;

.field private d:Lcom/hierynomus/asn1/m;

.field private e:[B

.field private f:[B


# direct methods
.method public constructor <init>()V
    .locals 2

    const/4 v0, 0x1

    const-string v1, "NegTokenTarg"

    .line 1
    invoke-direct {p0, v0, v1}, Lcom/hierynomus/spnego/d;-><init>(ILjava/lang/String;)V

    return-void
.end method

.method private a(Lcom/hierynomus/asn1/q;)V
    .locals 2
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Lcom/hierynomus/spnego/SpnegoException;
        }
    .end annotation

    .line 12
    instance-of v0, p1, Lcom/hierynomus/asn1/g;

    if-eqz v0, :cond_0

    .line 13
    check-cast p1, Lcom/hierynomus/asn1/g;

    invoke-virtual {p1}, Lcom/hierynomus/asn1/g;->getValue()Ljava/math/BigInteger;

    move-result-object p1

    iput-object p1, p0, Lcom/hierynomus/spnego/b;->c:Ljava/math/BigInteger;

    return-void

    .line 14
    :cond_0
    new-instance p1, Lcom/hierynomus/spnego/SpnegoException;

    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    const-string v1, "Expected the negResult (ENUMERATED) contents, not: "

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    iget-object v1, p0, Lcom/hierynomus/spnego/b;->d:Lcom/hierynomus/asn1/m;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    invoke-direct {p1, v0}, Lcom/hierynomus/spnego/SpnegoException;-><init>(Ljava/lang/String;)V

    throw p1
.end method

.method private b(Lcom/hierynomus/asn1/q;)V
    .locals 3
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Lcom/hierynomus/spnego/SpnegoException;
        }
    .end annotation

    .line 12
    instance-of v0, p1, Lcom/hierynomus/asn1/n;

    if-eqz v0, :cond_0

    .line 13
    check-cast p1, Lcom/hierynomus/asn1/n;

    invoke-virtual {p1}, Lcom/hierynomus/asn1/n;->j()[B

    move-result-object p1

    iput-object p1, p0, Lcom/hierynomus/spnego/b;->e:[B

    return-void

    .line 14
    :cond_0
    new-instance v0, Lcom/hierynomus/spnego/SpnegoException;

    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    const-string v2, "Expected the responseToken (OCTET_STRING) contents, not: "

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-direct {v0, p1}, Lcom/hierynomus/spnego/SpnegoException;-><init>(Ljava/lang/String;)V

    throw v0
.end method

.method private c(Lcom/hierynomus/asn1/q;)V
    .locals 3
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Lcom/hierynomus/spnego/SpnegoException;
        }
    .end annotation

    .line 1
    instance-of v0, p1, Lcom/hierynomus/asn1/m;

    if-eqz v0, :cond_0

    .line 2
    check-cast p1, Lcom/hierynomus/asn1/m;

    iput-object p1, p0, Lcom/hierynomus/spnego/b;->d:Lcom/hierynomus/asn1/m;

    return-void

    .line 3
    :cond_0
    new-instance v0, Lcom/hierynomus/spnego/SpnegoException;

    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    const-string v2, "Expected the supportedMech (OBJECT IDENTIFIER) contents, not: "

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/Object;)Ljava/lang/StringBuilder;

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-direct {v0, p1}, Lcom/hierynomus/spnego/SpnegoException;-><init>(Ljava/lang/String;)V

    throw v0
.end method


# virtual methods
.method public a(Lcom/hierynomus/protocol/commons/buffer/Buffer;)Lcom/hierynomus/spnego/b;
    .locals 1
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Lcom/hierynomus/protocol/commons/buffer/Buffer<",
            "*>;)",
            "Lcom/hierynomus/spnego/b;"
        }
    .end annotation

    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    .line 4
    :try_start_0
    new-instance v0, Lcom/hierynomus/asn1/i;

    invoke-virtual {p1}, Lcom/hierynomus/protocol/commons/buffer/Buffer;->d()[B

    move-result-object p1

    invoke-direct {v0, p1}, Lcom/hierynomus/asn1/i;-><init>([B)V

    invoke-virtual {v0}, Lcom/hierynomus/asn1/i;->readObject()Lcom/hierynomus/asn1/q;

    move-result-object p1

    .line 5
    invoke-virtual {p0, p1}, Lcom/hierynomus/spnego/d;->a(Lcom/hierynomus/asn1/e;)V
    :try_end_0
    .catch Lcom/hierynomus/spnego/SpnegoException; {:try_start_0 .. :try_end_0} :catch_0

    return-object p0

    :catch_0
    move-exception p1

    .line 6
    new-instance v0, Lcom/hierynomus/smbj/common/SMBRuntimeException;

    invoke-direct {v0, p1}, Lcom/hierynomus/smbj/common/SMBRuntimeException;-><init>(Ljava/lang/Throwable;)V

    throw v0
.end method

.method public a([B)Lcom/hierynomus/spnego/b;
    .locals 2
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    .line 3
    new-instance v0, Lcom/hierynomus/protocol/commons/buffer/Buffer$b;

    sget-object v1, Lcom/hierynomus/protocol/commons/buffer/a;->a:Lcom/hierynomus/protocol/commons/buffer/a;

    invoke-direct {v0, p1, v1}, Lcom/hierynomus/protocol/commons/buffer/Buffer$b;-><init>([BLcom/hierynomus/protocol/commons/buffer/a;)V

    invoke-virtual {p0, v0}, Lcom/hierynomus/spnego/b;->a(Lcom/hierynomus/protocol/commons/buffer/Buffer;)Lcom/hierynomus/spnego/b;

    return-object p0
.end method

.method public a()Ljava/math/BigInteger;
    .locals 1

    .line 15
    iget-object v0, p0, Lcom/hierynomus/spnego/b;->c:Ljava/math/BigInteger;

    return-object v0
.end method

.method protected a(Lcom/hierynomus/asn1/w;)V
    .locals 3
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Lcom/hierynomus/spnego/SpnegoException;
        }
    .end annotation

    .line 7
    invoke-virtual {p1}, Lcom/hierynomus/asn1/w;->k()I

    move-result v0

    if-eqz v0, :cond_2

    const/4 v1, 0x1

    if-eq v0, v1, :cond_1

    const/4 v1, 0x2

    if-ne v0, v1, :cond_0

    .line 8
    invoke-virtual {p1}, Lcom/hierynomus/asn1/w;->j()Lcom/hierynomus/asn1/q;

    move-result-object p1

    invoke-direct {p0, p1}, Lcom/hierynomus/spnego/b;->b(Lcom/hierynomus/asn1/q;)V

    goto :goto_0

    .line 9
    :cond_0
    new-instance v0, Lcom/hierynomus/spnego/SpnegoException;

    new-instance v1, Ljava/lang/StringBuilder;

    invoke-direct {v1}, Ljava/lang/StringBuilder;-><init>()V

    const-string v2, "Unknown Object Tag "

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {p1}, Lcom/hierynomus/asn1/w;->k()I

    move-result p1

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    const-string p1, " encountered."

    invoke-virtual {v1, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-direct {v0, p1}, Lcom/hierynomus/spnego/SpnegoException;-><init>(Ljava/lang/String;)V

    throw v0

    .line 10
    :cond_1
    invoke-virtual {p1}, Lcom/hierynomus/asn1/w;->j()Lcom/hierynomus/asn1/q;

    move-result-object p1

    invoke-direct {p0, p1}, Lcom/hierynomus/spnego/b;->c(Lcom/hierynomus/asn1/q;)V

    goto :goto_0

    .line 11
    :cond_2
    invoke-virtual {p1}, Lcom/hierynomus/asn1/w;->j()Lcom/hierynomus/asn1/q;

    move-result-object p1

    invoke-direct {p0, p1}, Lcom/hierynomus/spnego/b;->a(Lcom/hierynomus/asn1/q;)V

    :goto_0
    return-void
.end method

.method protected a(Lcom/hierynomus/protocol/commons/buffer/Buffer;Lcom/hierynomus/asn1/f;)V
    .locals 2
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Lcom/hierynomus/protocol/commons/buffer/Buffer<",
            "*>;",
            "Lcom/hierynomus/asn1/f;",
            ")V"
        }
    .end annotation

    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/io/IOException;
        }
    .end annotation

    .line 1
    new-instance v0, Lcom/hierynomus/asn1/f1;

    new-instance v1, Lcom/hierynomus/asn1/a1;

    invoke-direct {v1, p2}, Lcom/hierynomus/asn1/a1;-><init>(Lcom/hierynomus/asn1/f;)V

    const/4 p2, 0x1

    invoke-direct {v0, p2, p2, v1}, Lcom/hierynomus/asn1/f1;-><init>(ZILcom/hierynomus/asn1/e;)V

    .line 2
    invoke-virtual {v0}, Lcom/hierynomus/asn1/l;->e()[B

    move-result-object p2

    invoke-virtual {p1, p2}, Lcom/hierynomus/protocol/commons/buffer/Buffer;->a([B)Lcom/hierynomus/protocol/commons/buffer/Buffer;

    return-void
.end method

.method public b(Lcom/hierynomus/protocol/commons/buffer/Buffer;)V
    .locals 5
    .annotation system Ldalvik/annotation/Signature;
        value = {
            "(",
            "Lcom/hierynomus/protocol/commons/buffer/Buffer<",
            "*>;)V"
        }
    .end annotation

    .line 1
    :try_start_0
    new-instance v0, Lcom/hierynomus/asn1/f;

    invoke-direct {v0}, Lcom/hierynomus/asn1/f;-><init>()V

    .line 2
    iget-object v1, p0, Lcom/hierynomus/spnego/b;->c:Ljava/math/BigInteger;

    if-eqz v1, :cond_0

    .line 3
    new-instance v1, Lcom/hierynomus/asn1/f1;

    const/4 v2, 0x0

    new-instance v3, Lcom/hierynomus/asn1/g;

    iget-object v4, p0, Lcom/hierynomus/spnego/b;->c:Ljava/math/BigInteger;

    invoke-direct {v3, v4}, Lcom/hierynomus/asn1/g;-><init>(Ljava/math/BigInteger;)V

    invoke-direct {v1, v2, v3}, Lcom/hierynomus/asn1/f1;-><init>(ILcom/hierynomus/asn1/e;)V

    invoke-virtual {v0, v1}, Lcom/hierynomus/asn1/f;->a(Lcom/hierynomus/asn1/e;)V

    .line 4
    :cond_0
    iget-object v1, p0, Lcom/hierynomus/spnego/b;->d:Lcom/hierynomus/asn1/m;

    if-eqz v1, :cond_1

    .line 5
    new-instance v1, Lcom/hierynomus/asn1/f1;

    const/4 v2, 0x1

    iget-object v3, p0, Lcom/hierynomus/spnego/b;->d:Lcom/hierynomus/asn1/m;

    invoke-direct {v1, v2, v3}, Lcom/hierynomus/asn1/f1;-><init>(ILcom/hierynomus/asn1/e;)V

    invoke-virtual {v0, v1}, Lcom/hierynomus/asn1/f;->a(Lcom/hierynomus/asn1/e;)V

    .line 6
    :cond_1
    iget-object v1, p0, Lcom/hierynomus/spnego/b;->e:[B

    if-eqz v1, :cond_2

    iget-object v1, p0, Lcom/hierynomus/spnego/b;->e:[B

    array-length v1, v1

    if-lez v1, :cond_2

    .line 7
    new-instance v1, Lcom/hierynomus/asn1/f1;

    const/4 v2, 0x2

    new-instance v3, Lcom/hierynomus/asn1/w0;

    iget-object v4, p0, Lcom/hierynomus/spnego/b;->e:[B

    invoke-direct {v3, v4}, Lcom/hierynomus/asn1/w0;-><init>([B)V

    invoke-direct {v1, v2, v3}, Lcom/hierynomus/asn1/f1;-><init>(ILcom/hierynomus/asn1/e;)V

    invoke-virtual {v0, v1}, Lcom/hierynomus/asn1/f;->a(Lcom/hierynomus/asn1/e;)V

    .line 8
    :cond_2
    iget-object v1, p0, Lcom/hierynomus/spnego/b;->f:[B

    if-eqz v1, :cond_3

    iget-object v1, p0, Lcom/hierynomus/spnego/b;->f:[B

    array-length v1, v1

    if-lez v1, :cond_3

    .line 9
    new-instance v1, Lcom/hierynomus/asn1/f1;

    const/4 v2, 0x3

    new-instance v3, Lcom/hierynomus/asn1/w0;

    iget-object v4, p0, Lcom/hierynomus/spnego/b;->f:[B

    invoke-direct {v3, v4}, Lcom/hierynomus/asn1/w0;-><init>([B)V

    invoke-direct {v1, v2, v3}, Lcom/hierynomus/asn1/f1;-><init>(ILcom/hierynomus/asn1/e;)V

    invoke-virtual {v0, v1}, Lcom/hierynomus/asn1/f;->a(Lcom/hierynomus/asn1/e;)V

    .line 10
    :cond_3
    invoke-virtual {p0, p1, v0}, Lcom/hierynomus/spnego/b;->a(Lcom/hierynomus/protocol/commons/buffer/Buffer;Lcom/hierynomus/asn1/f;)V
    :try_end_0
    .catch Ljava/io/IOException; {:try_start_0 .. :try_end_0} :catch_0

    return-void

    :catch_0
    move-exception p1

    .line 11
    new-instance v0, Lcom/hierynomus/smbj/common/SMBRuntimeException;

    invoke-direct {v0, p1}, Lcom/hierynomus/smbj/common/SMBRuntimeException;-><init>(Ljava/lang/Throwable;)V

    throw v0
.end method

.method public b([B)V
    .locals 0

    .line 16
    iput-object p1, p0, Lcom/hierynomus/spnego/b;->e:[B

    return-void
.end method

.method public b()[B
    .locals 1

    .line 15
    iget-object v0, p0, Lcom/hierynomus/spnego/b;->e:[B

    return-object v0
.end method
